import Vue from 'vue'
import Router from 'vue-router'
import Login from "../views/Login.vue";
import Index from "../views/Index.vue";
import TransferAccounts from "../views/operate/TransferAccounts.vue";
import TransactionRecord from "../views/operate/TransactionRecord.vue";
import Balance from "../views/operate/Balance.vue";
import UpdatePassword from "../views/operate/UpdatePassword.vue";

Vue.use(Router)

export default new Router({
  routes: [
    {
      path: '/',
      redirect:'/login'
    },
    {
      path: '/login',
      name: 'Login',
      component: Login
    },
    {
      path: '/index',
      name: 'Index',
      component: Index,
      children:[
        {path: '/transferAccounts', name: 'TransferAccounts', component: TransferAccounts},
        {path: '/transactionRecord', name: 'TransactionRecord', component: TransactionRecord},
        {path: '/balance', name: 'Balance', component: Balance},
        {path: '/updatePassword', name: 'UpdatePassword', component: UpdatePassword}
      ]
    }
  ]
})
